//
//  DownloadData.h
//  YuanCheng
//
//  Created by dongshangtong on 16/3/14.
//  Copyright © 2016年 dongshangtong. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "AFNetworking.h"

typedef NS_ENUM(NSInteger,YCRequestSerializerType){
    YCRequestSerializerTypeForm = 0,      // 表单形式，默认
    YCRequestSerializerTypeJSON,          // JSON形式
    YCRequestSerializerTypePropertyList,  // PList形式
};

@interface DownloadData : NSObject



+ (void)getAccess_token;


+(void)get:(NSString *)url params:(NSDictionary *)params success:(void (^)(id json))success failure:(void (^)(NSError *error))failure;


+(void)post:(NSString *)url params:(NSDictionary *)params success:(void (^)(id json))success failure:(void (^)(NSError *error))failure;

+(void)post:(NSString *)url SerializerType:(YCRequestSerializerType)type params:(NSDictionary *)params success:(void (^)(id json))success failure:(void (^)(NSError *error))failure;



@end
